<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>回文数</title>
    <script>
        var num = prompt("请输入一个五位数字: ");
        var a = num%10;//个位数字
        var b = parseInt(num%100/10);//十位数字
        var c = parseInt(num%1000/100);//百位数字
        var d = parseInt(num%10000/1000);//千位数字
        var e = parseInt(num/10000);//万位数字
        var num=(a==e && b==d)?alert("是回文数"):alert("不是回文数");
    </script>
</head>
<body>
    
</body>
</html>